package com.haiyan.demo10_继承体系对象的内存图;
class Fu{
    int num=10;
    int numFu=100;
    public void method()
    {
        System.out.println("Fu method方法");
    }
}
class Zi extends Fu{
    int num=20;
    int numZi=200;
    public void show()
    {
        int num=30;
        System.out.println("局部变量num:"+num);
        System.out.println("本类成员变量num:"+this.num);
        System.out.println("父类成员变量num:"+super.num);
    }
    @Override
    public void method()
    {
        super.method();
        System.out.println("Zi method方法");
    }
}
public class Test {
    public static void main(String[] args) {
        Zi zi=new Zi();
        zi.show();
        zi.method();
    }
}
